<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>04_JS运算符</title>
</head>
<body>
<script>
    console.log(6 / 3);
    console.log(3 / 2);//1.5

    console.log(3 > 10);//false
    console.log(3 < '10');//false
    console.log('3' > 10);//false
    //如果比较运算符
    console.log('超'.charCodeAt());
    console.log('宇'.charCodeAt());
    console.log('超' > '宇');//true
    console.log('3' > '10');//true
    console.log('3'.charCodeAt());//51
    console.log('10'.charCodeAt());//49
    console.log('103'.charCodeAt(2));//51

    let a = 1;
    let b = true;
    console.log(a == b);//松散比较运算符，true
    console.log(a === b);//严格比较运算符,false

    let c = 0;
    console.log(c == 0? 'yes':'no');//yes
    console.log(c = 1? 'yes':'no');//no  =为赋值运算符

</script>
</body>
</html>